//
//  FGBaseAlertView.h
//  FGKit
//
//  Created by Lu feng on 2020/1/9.
//  Copyright © 2020 fengge. All rights reserved.
//

#import "FGBaseView.h"

@interface FGBaseAlertView : FGBaseView

/**    默认 0.69     */
@property (nonatomic, assign) CGFloat maskAlpha;

/**    设置点击contentView之外关闭弹框，默认点击不关闭 contentView = nil点哪里都关闭     */
- (void)setCanTouchDismiss:(BOOL)canTouchDismiss contentView:(UIView *)contentView;



/**
 * 代码创建
 */
+ (instancetype)showWithDelegate:(id<UIViewBaseDelegate>)delegate;
+ (instancetype)showActionWithIndex:(void(^)(NSInteger index))actionWithIndex;
+ (instancetype)showActionWithFlag:(void(^)(NSString *flag))actionWithFlag;

/**
 * xib创建
 */
+ (instancetype)showNibWithDelegate:(id<UIViewBaseDelegate>)delegate;
+ (instancetype)showNibActionWithIndex:(void(^)(NSInteger index))actionWithIndex;
+ (instancetype)showNibActionWithFlag:(void(^)(NSString *flag))actionWithFlag;

#pragma mark - action
/**    execute block     */
- (void)executeActionWithFlag:(NSString *)flag;
/**    execute block     */
- (void)executeActionWithIndex:(NSInteger)index;
/**    关闭     */
- (IBAction)dismiss;

@end
